Optimal. Leaf size=151 \[ -\frac {a+b \tan ^{-1}(c+d x)}{f (e+f x)}-\frac {b d \log \left (c^2+2 c d x+d^2 x^2+1\right )}{2 \left (\left (c^2+1\right ) f^2-2 c d e f+d^2 e^2\right )}+\frac {b d \log (e+f x)}{\left (c^2+1\right ) f^2-2 c d e f+d^2 e^2}+\frac {b d (d e-c f) \tan ^{-1}(c+d x)}{f \left (\left (c^2+1\right ) f^2-2 c d e f+d^2 e^2\right )} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.12, antiderivative size = 151, normalized size of antiderivative = 1.00, number of steps used = 8, number of rules used = 8, integrand size = 18, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.444, Rules used = {5045, 1982, 705, 31, 634, 618, 204, 628} \[ -\frac {a+b \tan ^{-1}(c+d x)}{f (e+f x)}-\frac {b d \log \left (c^2+2 c d x+d^2 x^2+1\right )}{2 \left (\left (c^2+1\right ) f^2-2 c d e f+d^2 e^2\right )}+\frac {b d \log (e+f x)}{\left (c^2+1\right ) f^2-2 c d e f+d^2 e^2}+\frac {b d (d e-c f) \tan ^{-1}(c+d x)}{f \left (\left (c^2+1\right ) f^2-2 c d e f+d^2 e^2\right )} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 31
Rule 204
Rule 618
Rule 628
Rule 634
Rule 705
Rule 1982
Rule 5045
Rubi steps
\begin {align*} \int \frac {a+b \tan ^{-1}(c+d x)}{(e+f x)^2} \, dx &=-\frac {a+b \tan ^{-1}(c+d x)}{f (e+f x)}+\frac {(b d) \int \frac {1}{(e+f x) \left (1+(c+d x)^2\right )} \, dx}{f}\\ &=-\frac {a+b \tan ^{-1}(c+d x)}{f (e+f x)}+\frac {(b d) \int \frac {1}{(e+f x) \left (1+c^2+2 c d x+d^2 x^2\right )} \, dx}{f}\\ &=-\frac {a+b \tan ^{-1}(c+d x)}{f (e+f x)}+\frac {(b d) \int \frac {d^2 e-2 c d f-d^2 f x}{1+c^2+2 c d x+d^2 x^2} \, dx}{f \left (d^2 e^2-2 c d e f+\left (1+c^2\right ) f^2\right )}+\frac {(b d f) \int \frac {1}{e+f x} \, dx}{d^2 e^2-2 c d e f+\left (1+c^2\right ) f^2}\\ &=-\frac {a+b \tan ^{-1}(c+d x)}{f (e+f x)}+\frac {b d \log (e+f x)}{d^2 e^2-2 c d e f+\left (1+c^2\right ) f^2}-\frac {(b d) \int \frac {2 c d+2 d^2 x}{1+c^2+2 c d x+d^2 x^2} \, dx}{2 \left (d^2 e^2-2 c d e f+\left (1+c^2\right ) f^2\right )}+\frac {\left (b d^2 (d e-c f)\right ) \int \frac {1}{1+c^2+2 c d x+d^2 x^2} \, dx}{f \left (d^2 e^2-2 c d e f+\left (1+c^2\right ) f^2\right )}\\ &=-\frac {a+b \tan ^{-1}(c+d x)}{f (e+f x)}+\frac {b d \log (e+f x)}{d^2 e^2-2 c d e f+\left (1+c^2\right ) f^2}-\frac {b d \log \left (1+c^2+2 c d x+d^2 x^2\right )}{2 \left (d^2 e^2-2 c d e f+\left (1+c^2\right ) f^2\right )}-\frac {\left (2 b d^2 (d e-c f)\right ) \operatorname {Subst}\left (\int \frac {1}{-4 d^2-x^2} \, dx,x,2 c d+2 d^2 x\right )}{f \left (d^2 e^2-2 c d e f+\left (1+c^2\right ) f^2\right )}\\ &=\frac {b d (d e-c f) \tan ^{-1}(c+d x)}{f \left (d^2 e^2-2 c d e f+\left (1+c^2\right ) f^2\right )}-\frac {a+b \tan ^{-1}(c+d x)}{f (e+f x)}+\frac {b d \log (e+f x)}{d^2 e^2-2 c d e f+\left (1+c^2\right ) f^2}-\frac {b d \log \left (1+c^2+2 c d x+d^2 x^2\right )}{2 \left (d^2 e^2-2 c d e f+\left (1+c^2\right ) f^2\right )}\\ \end {align*}
________________________________________________________________________________________
Mathematica [C] time = 0.21, size = 121, normalized size = 0.80 \[ \frac {-\frac {a+b \tan ^{-1}(c+d x)}{e+f x}+\frac {b d (i (-d e+(c+i) f) \log (-c-d x+i)+i (-c f+d e+i f) \log (c+d x+i)+2 f \log (d (e+f x)))}{2 \left (\left (c^2+1\right ) f^2-2 c d e f+d^2 e^2\right )}}{f} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.70, size = 190, normalized size = 1.26 \[ -\frac {2 \, a d^{2} e^{2} - 4 \, a c d e f + 2 \, {\left (a c^{2} + a\right )} f^{2} - 2 \, {\left (b c d e f - {\left (b c^{2} + b\right )} f^{2} + {\left (b d^{2} e f - b c d f^{2}\right )} x\right )} \arctan \left (d x + c\right ) + {\left (b d f^{2} x + b d e f\right )} \log \left (d^{2} x^{2} + 2 \, c d x + c^{2} + 1\right ) - 2 \, {\left (b d f^{2} x + b d e f\right )} \log \left (f x + e\right )}{2 \, {\left (d^{2} e^{3} f - 2 \, c d e^{2} f^{2} + {\left (c^{2} + 1\right )} e f^{3} + {\left (d^{2} e^{2} f^{2} - 2 \, c d e f^{3} + {\left (c^{2} + 1\right )} f^{4}\right )} x\right )}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [F] time = 0.00, size = 0, normalized size = 0.00 \[ \mathit {sage}_{0} x \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.05, size = 205, normalized size = 1.36 \[ -\frac {d a}{\left (d f x +d e \right ) f}-\frac {d b \arctan \left (d x +c \right )}{\left (d f x +d e \right ) f}+\frac {d b \ln \left (f \left (d x +c \right )-c f +d e \right )}{c^{2} f^{2}-2 c d e f +d^{2} e^{2}+f^{2}}-\frac {d b \ln \left (1+\left (d x +c \right )^{2}\right )}{2 \left (c^{2} f^{2}-2 c d e f +d^{2} e^{2}+f^{2}\right )}-\frac {d b \arctan \left (d x +c \right ) c}{c^{2} f^{2}-2 c d e f +d^{2} e^{2}+f^{2}}+\frac {d^{2} b \arctan \left (d x +c \right ) e}{f \left (c^{2} f^{2}-2 c d e f +d^{2} e^{2}+f^{2}\right )} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.42, size = 177, normalized size = 1.17 \[ \frac {1}{2} \, {\left (d {\left (\frac {2 \, {\left (d^{2} e - c d f\right )} \arctan \left (\frac {d^{2} x + c d}{d}\right )}{{\left (d^{2} e^{2} f - 2 \, c d e f^{2} + {\left (c^{2} + 1\right )} f^{3}\right )} d} - \frac {\log \left (d^{2} x^{2} + 2 \, c d x + c^{2} + 1\right )}{d^{2} e^{2} - 2 \, c d e f + {\left (c^{2} + 1\right )} f^{2}} + \frac {2 \, \log \left (f x + e\right )}{d^{2} e^{2} - 2 \, c d e f + {\left (c^{2} + 1\right )} f^{2}}\right )} - \frac {2 \, \arctan \left (d x + c\right )}{f^{2} x + e f}\right )} b - \frac {a}{f^{2} x + e f} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 1.83, size = 127, normalized size = 0.84 \[ \frac {b\,d\,\ln \left (e+f\,x\right )}{d^2\,e^2-2\,c\,d\,e\,f+\left (c^2+1\right )\,f^2}-\frac {b\,\mathrm {atan}\left (c+d\,x\right )}{f\,\left (e+f\,x\right )}-\frac {a}{x\,f^2+e\,f}-\frac {b\,d\,\ln \left (c+d\,x-\mathrm {i}\right )\,1{}\mathrm {i}}{2\,f\,\left (d\,e-c\,f+f\,1{}\mathrm {i}\right )}-\frac {b\,d\,\ln \left (c+d\,x+1{}\mathrm {i}\right )}{2\,f\,\left (f-c\,f\,1{}\mathrm {i}+d\,e\,1{}\mathrm {i}\right )} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F(-1)] time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________